KFbxIOPluginRegistry Class Reference

#include <kfbxiopluginregistry.h>

List of all members.


Detailed Description

This class serves as the registrar for file formats.

A file format must be registered when it is used by the FBX SDK.

This class also lets you create and read formats other than FBX SDK native formats

Definition at line 63 of file kfbxiopluginregistry.h.


Public Member Functions

  KFbxIOPluginRegistry ()
  Constructor.
virtual  ~KFbxIOPluginRegistry ()
  Destructor.
void  RegisterReader (char const *pPluginPath, int &pFirstPluginID, int &pRegisteredCount)
  Registers Reader from a plug-in path.
void  RegisterReader (KFbxReader::CreateFuncType pCreateF, KFbxReader::GetInfoFuncType pInfoF, int &pFirstPluginID, int &pRegisteredCount, KFbxReader::IOSettingsFillerFuncType pIOSettingsFillerF=NULL)
  Registers Readers.
void  RegisterWriter (char const *pPluginPath, int &pFirstPluginID, int &pRegisteredCount)
  Registers Writers from a plug-in path.
void  RegisterWriter (KFbxWriter::CreateFuncType pCreateF, KFbxWriter::GetInfoFuncType pInfoF, int &pFirstPluginID, int &pRegisteredCount, KFbxWriter::IOSettingsFillerFuncType pIOSettingsFillerF=NULL)
  Registers Writers.
KFbxReader CreateReader (KFbxSdkManager &pManager, KFbxImporter &pImporter, int pPluginID) const
  Creates a Reader in the Sdk Manager.
KFbxWriter CreateWriter (KFbxSdkManager &pManager, KFbxExporter &pExporter, int pPluginID) const
  Creates a Writer in the Sdk Manager.
int  FindReaderIDByExtension (char const *pExt) const
  Search for the Reader ID by the extension of the file.
int  FindWriterIDByExtension (char const *pExt) const
  Search for the Writer ID by the extension of the file.
int  FindReaderIDByDescription (char const *pDesc) const
  Search for the Reader ID by the description of the file format.
int  FindWriterIDByDescription (char const *pDesc) const
  Search for the Writer ID by the description of the file format.
bool  ReaderIsFBX (int pFileFormat) const
  Verifies if the file format of the Reader is FBX.
bool  WriterIsFBX (int pFileFormat) const
  Verifies if the file format of the Writer is FBX.
bool  ReaderIsGenuine (int pFileFormat) const
  Verifies if the file format of the Reader is genuine (internal).
bool  WriterIsGenuine (int pFileFormat) const
  Verifies if the file format of the Writer is genuine (internal).
int  GetReaderFormatCount () const
  Get the number of importable file formats.
int  GetWriterFormatCount () const
  Get the number of exportable file formats.
char const *  GetReaderFormatDescription (int pFileFormat) const
  Get the description of an importable file format.
char const *  GetWriterFormatDescription (int pFileFormat) const
  Get the description of an exportable file format.
char const *  GetReaderFormatExtension (int pFileFormat) const
  Get the file extension of an importable file format.
char const *  GetWriterFormatExtension (int pFileFormat) const
  Get the file extension of an exportable file format.
char const *const *  GetWritableVersions (int pFileFormat) const
  Get a list of the writable file format versions.
bool  DetectFileFormat (const char *pFileName, int &pFileFormat) const
  Detect the file format of the specified file.
int  GetNativeReaderFormat ()
  Gets the native reader file format.
int  GetNativeWriterFormat ()
  Gets the native writer file format.
void  FillIOSettingsForReadersRegistered (KFbxIOSettings &pIOS)
  Fills the IO Settings from all readers registered.
void  FillIOSettingsForWritersRegistered (KFbxIOSettings &pIOS)
  Fills the IO Settings from all writers registered.

Constructor & Destructor Documentation

Constructor.

virtual ~KFbxIOPluginRegistry (  )  [virtual]

Destructor.


Member Function Documentation

void RegisterReader ( char const *  pPluginPath,
int &  pFirstPluginID,
int &  pRegisteredCount  
)

Registers Reader from a plug-in path.

Parameters:
pPluginPath  path of the plug-in
pFirstPluginID  contains the ID of the first plug-in found
pRegisteredCount  contains the number of registered Readers

void RegisterReader ( KFbxReader::CreateFuncType  pCreateF,
KFbxReader::GetInfoFuncType  pInfoF,
int &  pFirstPluginID,
int &  pRegisteredCount,
KFbxReader::IOSettingsFillerFuncType  pIOSettingsFillerF = NULL  
)

Registers Readers.

Parameters:
pCreateF  Provide function information on file format
pInfoF  Provide information about the file format
pFirstPluginID  Contains the ID of the first plug-in found
pRegisteredCount  Contains the number of registered Readers
pIOSettingsFillerF 

void RegisterWriter ( char const *  pPluginPath,
int &  pFirstPluginID,
int &  pRegisteredCount  
)

Registers Writers from a plug-in path.

Parameters:
pPluginPath  Path of the plug-in
pFirstPluginID  Contains the ID of the first plug-in found
pRegisteredCount  Contains the number of registered Writers

void RegisterWriter ( KFbxWriter::CreateFuncType  pCreateF,
KFbxWriter::GetInfoFuncType  pInfoF,
int &  pFirstPluginID,
int &  pRegisteredCount,
KFbxWriter::IOSettingsFillerFuncType  pIOSettingsFillerF = NULL  
)

Registers Writers.

Parameters:
pCreateF  Provide function information on file format
pInfoF  Provide information about the file format
pFirstPluginID  Contains the ID of the first plug-in found
pRegisteredCount  Contains the number of registered writers
pIOSettingsFillerF 

KFbxReader* CreateReader ( KFbxSdkManager pManager,
KFbxImporter pImporter,
int  pPluginID  
) const

Creates a Reader in the Sdk Manager.

Parameters:
pManager  The Sdk Manager where the reader will be created
pImporter  Importer that will hold the created Reader
pPluginID  Plug-in ID to create a Reader from

KFbxWriter* CreateWriter ( KFbxSdkManager pManager,
KFbxExporter pExporter,
int  pPluginID  
) const

Creates a Writer in the Sdk Manager.

Parameters:
pManager  The Sdk Manager where the writer will be created
pExporter  Exporter that will hold the created Writer
pPluginID  Plug-in ID to create a Writer from

int FindReaderIDByExtension ( char const *  pExt  )  const

Search for the Reader ID by the extension of the file.

Parameters:
pExt  The file extension.
Returns:
The Reader ID if found, else returns -1

int FindWriterIDByExtension ( char const *  pExt  )  const

Search for the Writer ID by the extension of the file.

Parameters:
pExt  The file extension.
Returns:
The Writer ID if found, else returns -1

int FindReaderIDByDescription ( char const *  pDesc  )  const

Search for the Reader ID by the description of the file format.

Parameters:
pDesc  The description of the file format.
Returns:
The Reader ID if found, else returns -1

int FindWriterIDByDescription ( char const *  pDesc  )  const

Search for the Writer ID by the description of the file format.

Parameters:
pDesc  The description of the file format.
Returns:
The Writer ID if found, else returns -1

bool ReaderIsFBX ( int  pFileFormat  )  const

Verifies if the file format of the Reader is FBX.

Parameters:
pFileFormat  The file format.
Returns:
true if the file format of the Reader is FBX.

bool WriterIsFBX ( int  pFileFormat  )  const

Verifies if the file format of the Writer is FBX.

Parameters:
pFileFormat  The file format.
Returns:
true if the file format of the Writer is FBX.

bool ReaderIsGenuine ( int  pFileFormat  )  const

Verifies if the file format of the Reader is genuine (internal).

Parameters:
pFileFormat  The file format.
Returns:
true if the file format of the Reader is FBX.

bool WriterIsGenuine ( int  pFileFormat  )  const

Verifies if the file format of the Writer is genuine (internal).

Parameters:
pFileFormat  The file format.
Returns:
true if the file format of the Writer is FBX.

int GetReaderFormatCount (  )  const

Get the number of importable file formats.

Returns:
Number of importable formats.

int GetWriterFormatCount (  )  const

Get the number of exportable file formats.

Returns:
Number of exportable formats.
Remarks:
Multiple identifiers for the same format are counted as file formats. For example, eFBX_BINARY, eFBX_ASCII and eFBX_ENCRYPTED count as three file formats.

char const* GetReaderFormatDescription ( int  pFileFormat  )  const

Get the description of an importable file format.

Parameters:
pFileFormat  File format identifier.
Returns:
Pointer to the character representation of the description.

char const* GetWriterFormatDescription ( int  pFileFormat  )  const

Get the description of an exportable file format.

Parameters:
pFileFormat  File format identifier.
Returns:
Pointer to the character representation of the description.

char const* GetReaderFormatExtension ( int  pFileFormat  )  const

Get the file extension of an importable file format.

Parameters:
pFileFormat  File format identifier.
Returns:
Pointer to the character representation of the file extension.

char const* GetWriterFormatExtension ( int  pFileFormat  )  const

Get the file extension of an exportable file format.

Parameters:
pFileFormat  File format identifier.
Returns:
Pointer to the character representation of the file extension.

char const* const* GetWritableVersions ( int  pFileFormat  )  const

Get a list of the writable file format versions.

Parameters:
pFileFormat  File format identifier.
Returns:
Pointer to a list of user-readable strings representing the versions.

bool DetectFileFormat ( const char *  pFileName,
int &  pFileFormat  
) const

Detect the file format of the specified file.

Parameters:
pFileName  The file to determine his file format.
pFileFormat  The file format identifier if the function returns true. if the function returns false, unmodified otherwise.
Returns:
Return true if the file has been determined successfully, false otherwise.
Remarks:
This function attempts to detect the file format of pFileName based on the file extension and, in some cases, its content. This function may not be able to determine all file formats. Use this function as a helper before calling SetFileFormat().
Note:
The file must not be locked (already opened) for this function to succeed.

int GetNativeReaderFormat (  ) 

Gets the native reader file format.

Returns:
The native reader file format ID.

int GetNativeWriterFormat (  ) 

Gets the native writer file format.

Returns:
The native writer file format ID.

void FillIOSettingsForReadersRegistered ( KFbxIOSettings pIOS  ) 

Fills the IO Settings from all readers registered.

Parameters:
pIOS  The properties hierarchies to fill

void FillIOSettingsForWritersRegistered ( KFbxIOSettings pIOS  ) 

Fills the IO Settings from all writers registered.

Parameters:
pIOS  The properties hierarchies to fill
KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry
KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry KFbxIOPluginRegistry